<?php

class Default_UserController extends Zend_Controller_Action
{

    public function init()
    {
        /* Initialize action controller here */
    }

    public function indexAction()
    {
        // action body
    }

    public function myquestionAction()
    {
        // action body
        
        $auth = Zend_Auth::getInstance();
        
        
        if($auth->hasIdentity()){
        	$posts = new Default_Model_DbTable_Posts();
        	$authorId = $auth->getIdentity()->ID;
        	$this->view->isAuthenticated = true;
        	$this->view->posts = $posts->getByAuthor($authorId);
        }else{
        	$this->view->isAuthenticated = false;
        }
        
    }
    
    public function popuploginAction(){
    	
    }


}



